package sch.jl.caigou.impl;

import sch.jl.caigou.dao.GoodsDeleteDao;

public class GoodsDeleteImpl extends DaoImpl<Integer> implements GoodsDeleteDao
{
	private Integer sq_id=0;
	
	public void deleteData(String bh) {

		setSq_id(bh);
		String sql = "delete from think_shenqing where bh='"+bh+"'";
		delete(sql);
		sql  = "delete from think_shenhe where sq_id='"+sq_id+"'";
		delete(sql);
		sql = "delete from think_lingxing_sbjj where bh='"+bh+"'";
		delete(sql);
		sql  = "delete from think_liebiao_sbjj where sq_id='"+sq_id+"'";
		delete(sql);
	}
	

	public void setSq_id(String bh)
	{
		String sql="select sq_id from think_shenqing where bh='"+bh+"'";
		sq_id = getSingleVal(sql);
	}

}
